/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package com.mycompany.psc.data;

/**
 *
 * @author A7med
 */
public enum Roles {

    TENDER_BOQ("Tender Drawing", "TENDER_BOQ", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    FINAL_BOQ("Tender Drawing", "FINAL BOQ", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    AS_BUILT_DWG("Tender Drawing", "As Built Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    CONSTRUCTION_DWG("Construction Drawing", "Construction Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    SHOP_DWG("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    TECHNICAL_OFFER("Tender Drawing", "Technical Offer", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    DOCUMENT("Tender Drawing", "Document", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    SUB_CONTRACTOR_OFFER("Tender Drawing", "Sub Contractor Offer", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    SOIL_REPORTS("Tender Drawing", "Soil Reports", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    GENERAL_DOC("Tender Drawing", "Genral Documents", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    BOQ("Tender Drawing", "BOQ", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    TENDER_DOC("Tender Drawing", "Tender Documents", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    OWNER_CONTRACT("Tender Drawing", "Owner Contract", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    CONTRACT("Tender Drawing", "Contract", new String[]{"Admin Section1", "Admin Section2"}, new Roles[]{OWNER_CONTRACT}, false),
    TENDER_STUDY("TENDER_STUDY", "TENDER_STUDY", new String[]{"Mechanical Section1", "Mechanical Section2"}, new Roles[]{TECHNICAL_OFFER, DOCUMENT, SUB_CONTRACTOR_OFFER, SOIL_REPORTS, GENERAL_DOC, BOQ, TENDER_DOC, CONTRACT}, true),
    TENDER_DWG("Tender Drawing", "Tender Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    ARC("Tender Drawing", "ARC", new String[]{"Admin Section1", "Admin Section2"}, new Roles[]{TENDER_BOQ, FINAL_BOQ, AS_BUILT_DWG, SHOP_DWG, CONSTRUCTION_DWG}, false),
    STR("Tender Drawing", "STR", new String[]{"Admin Section1", "Admin Section2"}, new Roles[]{TENDER_BOQ, FINAL_BOQ, AS_BUILT_DWG, SHOP_DWG, CONSTRUCTION_DWG}, false),
    SUR("Tender Drawing", "SUR", new String[]{"Admin Section1", "Admin Section2"}, new Roles[]{TENDER_DWG, FINAL_BOQ, AS_BUILT_DWG, SHOP_DWG, CONSTRUCTION_DWG}, false),
    MECH("Tender Drawing", "MECH", new String[]{"Admin Section1", "Admin Section2"}, new Roles[]{TENDER_DWG, FINAL_BOQ, AS_BUILT_DWG, SHOP_DWG, CONSTRUCTION_DWG}, false),
    ELE("Tender Drawing", "ELE", new String[]{"Admin Section1", "Admin Section2"}, new Roles[]{TENDER_BOQ, FINAL_BOQ, AS_BUILT_DWG, SHOP_DWG, CONSTRUCTION_DWG}, false),
    DWG("Tender Drawing", "DWG", new String[]{"Admin Section1", "Admin Section2"}, new Roles[]{ARC, STR, SUR, MECH, ELE}, true),
    ADMIN("Admin", "Administration", new String[]{"Admin Section1", "Admin Section2"}, new Roles[]{ARC, STR, SUR}, true),
    TECH_OFFICE("Technical Office", "Tech Office", new String[]{"Electrical Section1", "Electrical Section2"}, new Roles[]{ARC, STR, SUR}, true),
    
    ELEC_MOCH_OFFICE("Elec/Mech Office", "Elec/Mech Office", new String[]{"Civile Section1", "Cevil Section2"}, new Roles[]{ELE, MECH}, true),
    TIME_SCEDULE("Elec/Mech Office", "Time Scedule", new String[]{"Civile Section1", "Cevil Section2"}, new Roles[]{ELE, MECH}, true),
    DOCUMENT_SUBMITTALS("Tender Drawing", "Document Submittals", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    DRAWING_SUBMITTALS("Tender Drawing", "Drawing Submittals", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    MATERIAL_SUBMITTALS("Tender Drawing", "Material Submittals", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    REQUEST_FOR_INFO("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    SITE_INSPECTION_REQUEST("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    APPROVED_QTY_SUR("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    WORK_SITE_INSTRUCTION("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    BUS_BORS_TEST("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    CABLE_TEST("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    EARTHING_TEST("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    GENERATOR_TESTS("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    ELEC_TEST("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, new Roles[]{BUS_BORS_TEST, CABLE_TEST,EARTHING_TEST,GENERATOR_TESTS}, false),
     CHILLED_WATER("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    FIREFIGHTING_TEST("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    HVAC("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    VALID("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    MECH_TEST("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, new Roles[]{CHILLED_WATER, FIREFIGHTING_TEST,HVAC,VALID}, false),
    SOIL_TOLERANCE_TEST("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    LOADING_LIMESTONE_TEST("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    AGGREGATES_SIEVES_TEST("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    CONCRETE_TEST("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    WATER_MIX_PH_MEASUREMENTS("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    TECH_TEST("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, new Roles[]{SOIL_TOLERANCE_TEST, LOADING_LIMESTONE_TEST,AGGREGATES_SIEVES_TEST,CONCRETE_TEST,WATER_MIX_PH_MEASUREMENTS}, false),
    QC("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"},new Roles[]{ELEC_TEST, MECH_TEST, TECH_TEST} , false),
    PROJECT_DOCUMENTS("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, new Roles[]{DOCUMENT_SUBMITTALS, DRAWING_SUBMITTALS,MATERIAL_SUBMITTALS,REQUEST_FOR_INFO,SITE_INSPECTION_REQUEST,APPROVED_QTY_SUR,WORK_SITE_INSTRUCTION,QC}, false),
    MIN_OF_MEETING("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    MEMO("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
     DAILY("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
      WEEKLY("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
       MONTHLY("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    REPORTS("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, new Roles[]{DAILY,WEEKLY,MONTHLY}, false),
    OUT_IN("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, null, false),
    OWNER("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, new Roles[]{OUT_IN}, false),
    CONSULTANT("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, new Roles[]{OUT_IN}, false),
    CONTRACTOR("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, new Roles[]{OUT_IN}, false),
    CORRISPONDANCE("Tender Drawing", "Shop Drawing", new String[]{"Admin Section1", "Admin Section2"}, new Roles[]{OWNER, CONSULTANT,CONTRACTOR}, false),
    
    
    DOCUMNENT_CONTROL("Elec/Mech Office", "Elec/Mech Office", new String[]{"Civile Section1", "Cevil Section2"}, new Roles[]{PROJECT_DOCUMENTS, MIN_OF_MEETING,MEMO,REPORTS,CORRISPONDANCE}, true),
    PHOTOS("Elec/Mech Office", "Elec/Mech Office", new String[]{"Civile Section1", "Cevil Section2"}, new Roles[]{ELE, MECH}, true),
    PROJECT_CONTROL("Elec/Mech Office", "Elec/Mech Office", new String[]{"Civile Section1", "Cevil Section2"}, new Roles[]{ELE, MECH}, true),
    FINANCIAL("Elec/Mech Office", "Elec/Mech Office", new String[]{"Civile Section1", "Cevil Section2"}, new Roles[]{ELE, MECH}, true),
    AUDIT("Elec/Mech Office", "Elec/Mech Office", new String[]{"Civile Section1", "Cevil Section2"}, new Roles[]{ELE, MECH}, true),
    HSSE("Elec/Mech Office", "Elec/Mech Office", new String[]{"Civile Section1", "Cevil Section2"}, new Roles[]{ELE, MECH}, true),
    TRANSPORTATION("Elec/Mech Office", "Elec/Mech Office", new String[]{"Civile Section1", "Cevil Section2"}, new Roles[]{ELE, MECH}, true),
    PURCHASING("Elec/Mech Office", "Elec/Mech Office", new String[]{"Civile Section1", "Cevil Section2"}, new Roles[]{ELE, MECH}, true),
    INVENTORY_CONTROL("Elec/Mech Office", "Elec/Mech Office", new String[]{"Civile Section1", "Cevil Section2"}, new Roles[]{ELE, MECH}, true),
    WAREHOUSE("Elec/Mech Office", "Elec/Mech Office", new String[]{"Civile Section1", "Cevil Section2"}, new Roles[]{ELE, MECH}, true),
    MARKETING("Elec/Mech Office", "Elec/Mech Office", new String[]{"Civile Section1", "Cevil Section2"}, new Roles[]{ELE, MECH}, true),
    MAINTAINANCE("Elec/Mech Office", "Elec/Mech Office", new String[]{"Civile Section1", "Cevil Section2"}, new Roles[]{ELE, MECH}, true),
    INVOICES("Elec/Mech Office", "Elec/Mech Office", new String[]{"Civile Section1", "Cevil Section2"}, new Roles[]{ELE, MECH}, true),;
    private final String label;
    private final String dept;
    private final boolean tab;

    public Roles[] getChildren() {
        return children;
    }
    private final String[] sections;
    private final Roles[] children;

    private Roles(String label, String dept, String[] sections, Roles[] children, boolean tab) {
        this.label = label;
        this.dept = dept;
        this.sections = sections;
        this.children = children;
        this.tab = tab;
    }

    public String getLabel() {
        return label;
    }

    public boolean isTab() {
        return tab;
    }

    public String getDept() {
        return dept;
    }

    public String[] getSections() {
        return sections;
    }

}
